<?php
/**
 * 
 * 清楚所有数据
 * @author apple
 *
 */


class Flush extends Admin_Controller
{
	
	public function __construct()
	{
		parent::__construct();
		
	}
	
	public function index()
	{
		/*
		$this->db->delete('cj_products'); 
		$this->db->delete('cj_reward');
		$this->db->delete('cj_stock');
		$this->db->delete('cj_lottery');
		$this->db->delete('cj_exchange');
		*/
		$this->db->empty_table('cj_products'); 
		$this->db->empty_table('cj_reward'); 
		$this->db->empty_table('cj_stock'); 
		$this->db->empty_table('cj_lottery'); 
		$this->db->empty_table('cj_exchange'); 
		redirect( 'adminroot/index' );
	}
}